<script lang="ts">

import Vue from 'vue';
import { Component } from "vue-property-decorator";
import ProfileFilter from './ProfileFilter.vue';
import ProfileList from './ProfileList.vue';
import { Teamap } from '../../core/Teamap'

@Component({
    data() {
        return {
            Profiler: Teamap.Profiler,
            keywords: Teamap.Profiler.keywords,
            profiles: []
        }
    },
    components: { ProfileFilter, ProfileList },
    methods: {
        init() {
            this.Profiler.find().then(result => {
                this.profiles = result.data
            })
        }
    },
    created() {
        this.init()
    }
})
export default class Profiles extends Vue {

}

</script>
<template>
    <view>
        <profile-filter :keywords="keywords" :data="profiles" />
        <profile-list :data="profiles" />
    </view>
</template>

<style scoped>
</style>